<?php
/* @var $this OperationController|TaskController|RoleController */
/* @var $model AuthItemForm */
/* @var $form TbActiveForm */

$this->breadcrumbs = array(
    $this->capitalize($this->getTypeText(true)) => array('index'),
    Yii::t('AuthModule.main', 'New {type}', array('{type}' => $this->getTypeText())),
);

$createUrl = $this->createUrl('create');
$indexUrl = $this->createUrl('index');
$typeText = $this->capitalize($this->getTypeText(true));
$this->setPageSubTitle(Yii::t('AuthModule.main', 'New {type}', array('{type}' => $this->getTypeText())));
?>
<div class="row">
	<div class="col-lg-12">
		<div class="panel panel-danger">
			<div class="panel-heading">
				<h4>创建新的<?php echo $typeText;?></h4>
				<div class="options">
				<a href="<?php echo $indexUrl;?>"><i class="icon-th-list">返回<?php echo $typeText;?>列表</i></a>
				
			    </div>
			</div>
			<div class="panel-body">

<?php $form = $this->beginWidget(
    'bootstrap.widgets.BsActiveForm',
    array(
        'layout' => BSHtml::FORM_LAYOUT_HORIZONTAL,
    )
); ?>

<?php echo $form->hiddenField($model, 'type'); ?>
<?php echo $form->textFieldControlGroup($model, 'name'); ?>
<?php echo $form->textFieldControlGroup($model, 'description'); ?>

    <div class="form-actions">
        <?php echo BSHtml::submitButton(
            Yii::t('AuthModule.main', 'Create'),
            array(
                'color' => BSHtml::BUTTON_COLOR_PRIMARY,
            )
        ); ?>
        <?php echo BSHtml::linkButton(
            Yii::t('AuthModule.main', 'Cancel'),
            array(
                'color' => BSHtml::BUTTON_COLOR_LINK,
                'url' => array('index'),
            )
        ); ?>
    </div>

<?php $this->endWidget(); ?>
</div> <!-- end panel-body -->
		</div>
	</div>
</div> <!-- end row -->
